﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;

namespace BackOffice
{
    public partial class Advertisement_Maintenance3 : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                bindAdvertisementPeriod();
                bindAdvertisementPictureSize();
            }
        }

        protected void bindAdvertisementPeriod()
        {
            DataTable dt = new DataTable();
            dt = Maintenance.listAdvertisementPeriod();

            rblPeriod.DataSource = dt;
            rblPeriod.DataTextField = "Period";
            rblPeriod.DataValueField = "Period";
            rblPeriod.DataBind();
        }

        protected void bindAdvertisementPictureSize()
        {
            DataTable dt = new DataTable();
            dt = Maintenance.listAdvertisementPictureSize();

            rblPicSize.DataSource = dt;
            rblPicSize.DataTextField = "PictureSize";
            rblPicSize.DataValueField = "price";
            rblPicSize.DataBind();
        }

        protected void btnAdd2_Click(object sender, EventArgs e)
        {
            string value1 = rblPeriod.SelectedValue.ToString();
            string value2 = rblPicSize.SelectedValue.ToString();
        }

        protected void btnRewardList_Click(object sender, ImageClickEventArgs e)
        {

        }

        protected void btnUpload_Click(object sender, EventArgs e)
        {

        }
    }
}